package cn.itcast.crm.service;

import java.util.List;

import javax.ws.rs.GET;
import javax.ws.rs.PUT;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;

import cn.itcast.crm.domain.Customer;

public interface CostomerService {
	
	// 查询所有未关联客户列表
	@Path("/nosssociationcustomers")
	@GET
	@Produces({"application/xml","application/json"})
	public List<Customer> findNoAssociationCustomers();
	
	
	// 查询所有已关联客户列表,将参数注入进来
	@Path("/associationfixedareacustomers/{fixedareaid}")
	@GET
	@Produces({"application/xml","application/json"})
	public List<Customer> findHasAssociationFixedAreaCustomers(@PathParam("fixedareaid") String fixedAreaId);
	
	// 将客户列表关联到定区上，将所有客户id拼成字符串 1,2,3
	// 且没有通过url传递参数用 @QueryParam
	@Path("/associationcustomerstofixedarea")
	@PUT
	public void associationCustomersToFixedArea(@QueryParam("customerIdStr") String customerIdStr,
												@QueryParam("fixedAreaId") String fixedAreaId);
		
	

}
